package com.xinyuan;

import com.xinyuan.utils.SpringUtil;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Import;
import org.springframework.scheduling.annotation.EnableAsync;

@SpringBootApplication
@MapperScan(basePackages = "com.xinyuan.mapper")
@ServletComponentScan(basePackages = "com.xinyuan.servlet")
@ComponentScan({"com.xinyuan.controller","com.xinyuan.service"})
@EnableAsync
public class Ameco527Application extends SpringBootServletInitializer{

    @Override
    protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
        return builder.sources(Ameco527Application.class);
    }

    public static void main(String[] args) {
        SpringApplication.run(Ameco527Application.class, args);
    }
}
